// vite.config.ts
import { defineConfig } from "file:///E:/tetrisv3/tetris-v3/node_modules/vite/dist/node/index.js";
import vue from "file:///E:/tetrisv3/tetris-v3/node_modules/@vitejs/plugin-vue/dist/index.mjs";
import path from "path";
import AutoImport from "file:///E:/tetrisv3/tetris-v3/node_modules/unplugin-auto-import/dist/vite.js";
import Components from "file:///E:/tetrisv3/tetris-v3/node_modules/unplugin-vue-components/dist/vite.js";
import { ElementPlusResolver } from "file:///E:/tetrisv3/tetris-v3/node_modules/unplugin-vue-components/dist/resolvers.js";
import tailwindcss from "file:///E:/tetrisv3/tetris-v3/node_modules/tailwindcss/lib/index.js";
import autoprefixer from "file:///E:/tetrisv3/tetris-v3/node_modules/autoprefixer/lib/autoprefixer.js";
import { VitePWA } from "file:///E:/tetrisv3/tetris-v3/node_modules/vite-plugin-pwa/dist/index.js";
import viteCompression from "file:///E:/tetrisv3/tetris-v3/node_modules/vite-plugin-compression/dist/index.mjs";
import { createSvgIconsPlugin } from "file:///E:/tetrisv3/tetris-v3/node_modules/vite-plugin-svg-icons/dist/index.mjs";
var __vite_injected_original_dirname = "E:\\tetrisv3\\tetris-v3";
var vite_config_default = defineConfig({
  resolve: {
    extensions: [".vue", ".ts", ".js", ".json"],
    alias: {
      "@": path.resolve(__vite_injected_original_dirname, ".", "src")
    }
  },
  plugins: [
    vue(),
    AutoImport({
      resolvers: [ElementPlusResolver()]
    }),
    Components({
      resolvers: [ElementPlusResolver()]
    }),
    VitePWA({
      registerType: "autoUpdate",
      devOptions: {
        enabled: true,
        type: "module"
      },
      workbox: {
        runtimeCaching: [
          {
            urlPattern: /.*/,
            handler: "StaleWhileRevalidate"
          }
        ],
        maximumFileSizeToCacheInBytes: 4 * 1024 * 1024
        // 需要缓存的最大文件大小
      },
      manifest: {
        "name": "Tetris V3",
        "short_name": "Tetris V3",
        "description": "A Tetris game, running on the web, responsive and installable.",
        "display": "standalone",
        "theme_color": "#111",
        "start_url": "/",
        "icons": [
          {
            "src": "/icon.png",
            "type": "image/png",
            "sizes": "171x171"
          }
        ],
        "orientation": "any",
        "background_color": "#fff",
        "lang": "en",
        "categories": [
          "game"
        ],
        "screenshots": [
          {
            "src": "/sssample.jpg",
            "type": "image/jpg",
            "sizes": "414x736",
            "form_factor": "narrow"
          }
        ]
      }
    }),
    viteCompression({
      // 压缩
      verbose: true,
      disable: false,
      threshold: 10240,
      algorithm: "gzip",
      ext: ".gz"
    }),
    createSvgIconsPlugin({
      iconDirs: [path.resolve(process.cwd(), "src/assets/svg")],
      symbolId: "icon-[dir]-[name]"
    })
  ],
  server: {
    host: "0.0.0.0"
  },
  css: {
    postcss: {
      plugins: [
        tailwindcss,
        autoprefixer
      ]
    }
  },
  build: {
    assetsInlineLimit: 0,
    // 原为4k 改为0 避免小音频base64化不进行打包
    rollupOptions: {
      // 打包后文件名不哈希化
      output: {
        entryFileNames: `[name].js`,
        chunkFileNames: `module/[name].js`,
        assetFileNames: `assets/[name].[ext]`
      }
    }
  }
  // 生产环境启动
  // esbuild: { // 去除console和debugger
  //   drop: ['console', 'debugger']
  // },
});
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCJFOlxcXFx0ZXRyaXN2M1xcXFx0ZXRyaXMtdjNcIjtjb25zdCBfX3ZpdGVfaW5qZWN0ZWRfb3JpZ2luYWxfZmlsZW5hbWUgPSBcIkU6XFxcXHRldHJpc3YzXFxcXHRldHJpcy12M1xcXFx2aXRlLmNvbmZpZy50c1wiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9pbXBvcnRfbWV0YV91cmwgPSBcImZpbGU6Ly8vRTovdGV0cmlzdjMvdGV0cmlzLXYzL3ZpdGUuY29uZmlnLnRzXCI7aW1wb3J0IHsgZG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HJlc29sdmVyczogW0VsZW1lbnRQbHVzUmVzb2x2ZXIoKV1cclxuICAgICAgICB9KSxcclxuICAgICAgICBDb21wb25lbnRzKHtcclxuICAgICAgICAgICAgcmVzb2x2ZXJzOiBbRWxlbWVudFBsdXNSZXNvbHZlcigpXVxyXG4gICAgICAgIH0pLFxyXG4gICAgICAgIFZpdGVQV0Eoe1xyXG4gICAgICAgICAgICByZWdpc3RlclR5cGU6ICdhdXRvVXBkYXRlJyxcclxuICAgICAgICAgICAgZGV2T3B0aW9uczoge1xyXG4gICAgICAgICAgICAgICAgZW5hYmxlZDogdHJ1ZSxcclxuICAgICAgICAgICAgICAgIHR5cGU6ICdtb2R1bGUnXHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIHdvcmtib3g6IHtcclxuICAgICAgICAgICAgICAgIHJ1bnRpbWVDYWNoaW5nOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB1cmxQYXR0ZXJuOiAvLiovLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBoYW5kbGVyOiAnU3RhbGVXaGlsZVJldmFsaWRhdGUnXHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgXSxcclxuICAgICAgICAgICAgICAgIG1heGltdW1GaWxlU2l6ZVRvQ2FjaGVJbkJ5dGVzOiA0ICogMTAyNCAqIDEwMjQgLy8gXHU5NzAwXHU4OTgxXHU3RjEzXHU1QjU4XHU3Njg0XHU2NzAwXHU1OTI3XHU2NTg3XHU0RUY2XHU1OTI3XHU1QzBGXHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgIG1hbmlmZXN0OiB7XHJcbiAgICAgICAgICAgICAgICBcIm5hbWVcIjogXCJUZXRyaXMgVjNcIixcclxuICAgICAgICAgICAgICAgIFwic2hvcnRfbmFtZVwiOiBcIlRldHJpcyBWM1wiLFxyXG4gICAgICAgICAgICAgICAgXCJkZXNjcmlwdGlvblwiOiBcIkEgVGV0cmlzIGdhbWUsIHJ1bm5pbmcgb24gdGhlIHdlYiwgcmVzcG9uc2l2ZSBhbmQgaW5zdGFsbGFibGUuXCIsXHJcbiAgICAgICAgICAgICAgICBcImRpc3BsYXlcIjogXCJzdGFuZGFsb25lXCIsXHJcbiAgICAgICAgICAgICAgICBcInRoZW1lX2NvbG9yXCI6IFwiIzExMVwiLFxyXG4gICAgICAgICAgICAgICAgXCJzdGFydF91cmxcIjogXCIvXCIsXHJcbiAgICAgICAgICAgICAgICBcImljb25zXCI6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIFwic3JjXCI6IFwiL2ljb24ucG5nXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIFwidHlwZVwiOiBcImltYWdlL3BuZ1wiLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBcInNpemVzXCI6IFwiMTcxeDE3MVwiXHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgXSxcclxuICAgICAgICAgICAgICAgIFwib3JpZW50YXRpb25cIjogXCJhbnlcIixcclxuICAgICAgICAgICAgICAgIFwiYmFja2dyb3VuZF9jb2xvclwiOiBcIiNmZmZcIixcclxuICAgICAgICAgICAgICAgIFwibGFuZ1wiOiBcImVuXCIsXHJcbiAgICAgICAgICAgICAgICBcImNhdGVnb3JpZXNcIjogW1xyXG4gICAgICAgICAgICAgICAgICAgIFwiZ2FtZVwiXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICAgICAgXCJzY3JlZW5zaG90c1wiOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBcInNyY1wiOiBcIi9zc3NhbXBsZS5qcGdcIixcclxuICAgICAgICAgICAgICAgICAgICAgICAgXCJ0eXBlXCI6IFwiaW1hZ2UvanBnXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIFwic2l6ZXNcIjogXCI0MTR4NzM2XCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIFwiZm9ybV9mYWN0b3JcIjogXCJuYXJyb3dcIlxyXG4gICAgICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIF1cclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0pLFxyXG4gICAgICAgIHZpdGVDb21wcmVzc2lvbih7IC8vIFx1NTM4Qlx1N0YyOVxyXG4gICAgICAgICAgICB2ZXJib3NlOiB0cnVlLFxyXG4gICAgICAgICAgICBkaXNhYmxlOiBmYWxzZSxcclxuICAgICAgICAgICAgdGhyZXNob2xkOiAxMDI0MCxcclxuICAgICAgICAgICAgYWxnb3JpdGhtOiAnZ3ppcCcsXHJcbiAgICAgICAgICAgIGV4dDogJy5neicsXHJcbiAgICAgICAgfSksXHJcbiAgICAgICAgY3JlYXRlU3ZnSWNvbnNQbHVnaW4oe1xyXG4gICAgICAgICAgICBpY29uRGlyczogW3BhdGgucmVzb2x2ZShwcm9jZXNzLmN3ZCgpLCAnc3JjL2Fzc2V0cy9zdmcnKV0sXHJcbiAgICAgICAgICAgIHN5bWJvbElkOiAnaWNvbi1bZGlyXS1bbmFtZV0nLFxyXG4gICAgICAgIH0pLFxyXG4gICAgXSxcclxuICAgIHNlcnZlcjoge1xyXG4gICAgICAgIGhvc3Q6ICcwLjAuMC4wJ1xyXG4gICAgfSxcclxuICAgIGNzczoge1xyXG4gICAgICAgIHBvc3Rjc3M6IHtcclxuICAgICAgICAgICAgcGx1Z2luczogW1xyXG4gICAgICAgICAgICAgICAgdGFpbHdpbmRjc3MsXHJcbiAgICAgICAgICAgICAgICBhdXRvcHJlZml4ZXJcclxuICAgICAgICAgICAgXVxyXG4gICAgICAgIH1cclxuICAgIH0sXHJcbiAgICBidWlsZDoge1xyXG4gICAgICAgIGFzc2V0c0lubGluZUxpbWl0OiAwLCAvLyBcdTUzOUZcdTRFM0E0ayBcdTY1MzlcdTRFM0EwIFx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